/*
 * CS_REG_PVP_WIN_MESSAGE.cpp
 *
 *  Created on: 2013. 10. 30.
 *      Author: mega@gamevil.com
 */

#include "../../Command.h"
#include "../../User.h"

namespace ProjectZ { namespace NCommand {

void Command::CS_REG_PVP_WIN_MESSAGE(User * pUser, ::Network::Packet * pPacket)
{
	PREPARE_PACKET;

	pUser->GetCharacterInfo().win_comment.clear();

	Toolkit::Str<30> winComment;
	*pPacket >> winComment;

	pUser->GetCharacterInfo().win_comment.assign(winComment.c_str());

	DEBUGLOG("CS_REG_PVP_WIN_MESSAGE : user_seq=%d", pUser->GetUserSeq());

	::Network::Packet * pAck = ::Network::GETPACKETPOOL()->SEND_NEW();
	*pAck << static_cast<int16_t>(ACK_OK);
	pAck->MakePacket(CMD_SC_REG_PVP_WIN_MESSAGE);

	pUser->Send(pAck);
}

} /*NCommand*/ } /*ProjectZ*/


